Skip to content

Added surface area calculation for pyramid - #7704

Closed
BASHI3Rmain wants to merge 1 commit into
TheAlgorithms:masterfrom
BASHI3Rmain:new_branch
Closed

BASHI3Rmain wants to merge 1 commit into
TheAlgorithms:masterfrom
BASHI3Rmain:new_branch

Conversation

@BASHI3Rmain

Copy link
Copy Markdown
  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized it.
  • All filenames are in PascalCase.
  • All functions and variable names follow Java naming conventions.
  • All new algorithms have a URL in their comments that points to Wikipedia or other similar explanations.
  • All new algorithms include a corresponding test class that validates their functionality.
  • All new code is formatted with clang-format -i --style=file path/to/your/file.java

* @param slantHeight slant height of the pyramid
* @return surface area of the given pyramid
*/
public static double surfaceAreaPyramid(final double sideLength, final double slantHeight) {

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fail on here, why?

@DenizAltunkapan

Copy link
Copy Markdown
Member

Thanks for contributing. Area.java already contains the proposed pyramid surface area calculation. This PR adds the same method again, introducing duplicate functionality and inconsistent formatting. Closing as redundant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants